package Tests;

import org.jrabbit.base.sound.Music;
import org.jrabbit.standard.game.main.StandardGame;

import Code.Basic.Structures.Wall;
import Code.Basic.World.GameWorld;
import Code.Objects.Characters.Player.Player;
import Code.Objects.Misc.HealingStation;

public class DeadSteelTest4 extends StandardGame
{

	public DeadSteelTest4()
	{
		super("Dead Steel", "Resources/Images/General/Icon.png");
	}
	
	protected void setup()
	{
		GameWorld GW = new GameWorld();
		GW.addPlayer(new Player());
		
		GW.makeCurrent();
		GW.initialize();

		Music.loop("Resources/Sounds/Music/Pipes.ogg");
		profiler.createNewTracker("Physics");
		
		GW.getPlayer().setEnemyGeneratorParameters(10, 1500);
		GW.getPlayer().setEnemyGeneratorEnable();
		
		//  -- Buildings -----------------
		
		// Building A
		Wall BuildingAWall3 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingAWall3.setLocation(560, -40);
		BuildingAWall3.setRotation(-45);
		GW.addObstacle(BuildingAWall3, "Structures");
		
		Wall BuildingAWall4 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingAWall4.setLocation(840, -40);
		BuildingAWall4.setRotation(45);
		GW.addObstacle(BuildingAWall4, "Structures");
		
		Wall BuildingAWall1 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingAWall1.setLocation(700, 100);
		BuildingAWall1.setRotation(0);
		GW.addObstacle(BuildingAWall1, "Structures");
		
		Wall BuildingAWall2 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingAWall2.setLocation(700, -100);
		BuildingAWall2.setRotation(0);
		GW.addObstacle(BuildingAWall2, "Structures");
		
		
		// Building B
		Wall BuildingBWall1 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingBWall1.setLocation(355, -845);
		BuildingBWall1.setRotation(-45);
		GW.addObstacle(BuildingBWall1, "Structures");
		
		Wall BuildingBWall2 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingBWall2.setLocation(495, -705);
		BuildingBWall2.setRotation(-45);
		GW.addObstacle(BuildingBWall2, "Structures");
		

		// Building C
		Wall BuildingCWall6 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingCWall6.setLocation(-1000, -620);
		BuildingCWall6.setRotation(-18);
		GW.addObstacle(BuildingCWall6, "Structures");
		
		Wall BuildingCWall1 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 2);
		BuildingCWall1.setLocation(-500, -900);
		BuildingCWall1.setRotation(0);
		GW.addObstacle(BuildingCWall1, "Structures");
		
		Wall BuildingCWall2 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 0.5f);
		BuildingCWall2.setLocation(-700, -700);
		BuildingCWall2.setRotation(0);
		GW.addObstacle(BuildingCWall2, "Structures");
		
		Wall BuildingCWall3 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingCWall3.setLocation(-1000, -500);
		BuildingCWall3.setRotation(0);
		GW.addObstacle(BuildingCWall3, "Structures");
		
		Wall BuildingCWall4 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingCWall4.setLocation(-1000, -300);
		BuildingCWall4.setRotation(0);
		GW.addObstacle(BuildingCWall4, "Structures");
		
		Wall BuildingCWall5 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingCWall5.setLocation(-700, -100);
		BuildingCWall5.setRotation(0);
		GW.addObstacle(BuildingCWall5, "Structures");
		
		
		// Building D
		Wall BuildingDWall1 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingDWall1.setLocation(-1100, 300);
		BuildingDWall1.setRotation(0);
		GW.addObstacle(BuildingDWall1, "Structures");
		
		
		// Building E
		Wall BuildingEWall1 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 2);
		BuildingEWall1.setLocation(-500, 600);
		BuildingEWall1.setRotation(90);
		GW.addObstacle(BuildingEWall1, "Structures");
		
		Wall BuildingEWall2 = new Wall("Resources/Images/Terrain/Environment/Brick2.png", 1);
		BuildingEWall2.setLocation(-300, 700);
		BuildingEWall2.setRotation(0);
		GW.addObstacle(BuildingEWall2, "Structures");
		
		//  --------------------
		
		GW.addCharacter(new HealingStation(250, 100), "Structures");
	}
	
	public static void main(String[] args)
	{
		init();
		new DeadSteelTest4().run();
	}
	
}
